<?php
/**
 * Created by JetBrains PhpStorm.
 * User: user
 * Date: 3/17/12
 * Time: 9:56 PM
 * To change this template use File | Settings | File Templates.
 */
class Admin_Model_ProductCategory extends Zend_Db_Table_Abstract{

    protected $_name = 'loai_san_pham';
    public function getProductCategory(){
        echo '<br>' .  __CLASS__ . ' - ' .__FUNCTION__;
    }

    public function addAction(){
        $form = new Admin_Form_ProductCategory();
        $form->submit->setLabel('Thêm');
        $this->view->form = $form;
        /*if ($this->getRequest()->isPost()) {
            $formData = $this->getRequest()->getPost();
            if ($form->isValid($formData)) {
                $ten = $form->getValue('ten');
                $mo_ta = $form->getValue('mo_ta');
                $ma_loai_cha = (int)$form->getValue('ma_loai_cha');
                $thu_tu_hien_thi = $form->getValue('thu_tu_hien_thi');
                $articlecategory = new Admin_Model_ArticleCategory();
                $articlecategory->addArticleCategory($ten, $mo_ta, $ma_loai_cha, $thu_tu_hien_thi);
                $this->_helper->redirector('index');
            } else {
                $form->populate($formData);
            }
        }
        */
    }
}
 
